{extend name="index/index"}

{block name="main"}

<div class="tpl-content-wrapper">
    <div class="tpl-content-page-title">
        QBQ 编辑房源信息
    </div>
    <ol class="am-breadcrumb">
        <li><a href="{:url('admin/index/index')}" class="am-icon-home">首页</a></li>
        <li><a href="{:url('admin/house/index')}">房源列表</a></li>
        <li class="am-active">编辑房源信息</li>
    </ol>
    <div class="tpl-portlet-components">
        <div class="portlet-title">
            <div class="caption font-green bold">
                <span class="am-icon-code"></span> 编辑房源信息
            </div>

        </div>

        <div class="tpl-block">

            <div class="am-g">
                <div class="tpl-form-body tpl-form-line">
                    <form class="am-form tpl-form-line-form" action="{:url('admin/Review/update',['id'=>$data['id']])}" method="post" enctype="multipart/form-data">
                        <input type="hidden" name="_method" value="put">
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房源区域 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <select name="add">
                                    {volist name="$arr" id="v"}
                                    {if condition="$v == $data['add']"}
                                    <option value="{$v}" selected>{$v}</option>
                                    {else /}
                                    <option value="{$v}">{$v}</option>
                                    {/if}
                                    {/volist}
                                </select>
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房源地址 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" id="user-name" value="{$data['address']}" name="address">
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房间大小 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" id="user-name" id="user-name" value="{$data['area']}" name="area">
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房租价格 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" id="user-name" id="user-name" value="{$data['rent']}" name="rent">
                                <small></small>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">户型 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <select name="cid">
                                    {volist name="$type" id="v"}
                                    {if condition="$v['id'] == $data['cid']"}
                                    <option value="{$v['id']}" selected>{$v['name']}</option>
                                    {else /}
                                    <option value="{$v['id']}">{$v['name']}</option>
                                    {/if}
                                    {/volist}
                                </select>
                                <small></small>
                            </div>
                        </div>

                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房间朝向 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                {switch name="$data['direction']"}
                                {case value="1"}
                                <input type="radio" value="1" name="direction" checked>东&nbsp;
                                <input type="radio" value="2" name="direction">南&nbsp;
                                <input type="radio" value="3" name="direction">西&nbsp;
                                <input type="radio" value="4" name="direction">北
                                {/case}
                                {case value="2"}
                                <input type="radio" value="1" name="direction">东&nbsp;
                                <input type="radio" value="2" name="direction" checked>南&nbsp;
                                <input type="radio" value="3" name="direction">西&nbsp;
                                <input type="radio" value="4" name="direction">北
                                {/case}
                                {case value="3"}
                                <input type="radio" value="1" name="direction">东&nbsp;
                                <input type="radio" value="2" name="direction">南&nbsp;
                                <input type="radio" value="3" name="direction" checked>西&nbsp;
                                <input type="radio" value="4" name="direction">北
                                {/case}
                                {case value="4"}
                                <input type="radio" value="1" name="direction">东&nbsp;
                                <input type="radio" value="2" name="direction">南&nbsp;
                                <input type="radio" value="3" name="direction">西&nbsp;
                                <input type="radio" value="4" name="direction" checked>北
                                {/case}
                                {/switch}
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">装修 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                {switch name="$data['fixture']"}
                                {case value="1"}
                                <input type="radio" name="fixture" value="1" checked>精装修&nbsp;
                                <input type="radio" name="fixture" value="2">简装修&nbsp;
                                {/case}
                                {case value="2"}
                                <input type="radio" name="fixture" value="1">精装修&nbsp;
                                <input type="radio" name="fixture" value="2" checked>简装修&nbsp;
                                {/case}
                                {/switch}
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">楼层 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                {switch name="$data['floor']"}
                                {case value="1"}
                                <input type="radio" name="floor" value="1" checked>1~6&nbsp;
                                <input type="radio" name="floor" value="2">6~12&nbsp;
                                <input type="radio" name="floor" value="3">12~18&nbsp;
                                <input type="radio" name="floor" value="4">18~24&nbsp;
                                <input type="radio" name="floor" value="5">24以上
                                {/case}
                                {case value="2"}
                                <input type="radio" name="floor" value="1">1~6&nbsp;
                                <input type="radio" name="floor" value="2" checked>6~12&nbsp;
                                <input type="radio" name="floor" value="3">12~18&nbsp;
                                <input type="radio" name="floor" value="4">18~24&nbsp;
                                <input type="radio" name="floor" value="5">24以上
                                {/case}
                                {case value="3"}
                                <input type="radio" name="floor" value="1">1~6&nbsp;
                                <input type="radio" name="floor" value="2">6~12&nbsp;
                                <input type="radio" name="floor" value="3" checked>12~18&nbsp;
                                <input type="radio" name="floor" value="4">18~24&nbsp;
                                <input type="radio" name="floor" value="5">24以上
                                {/case}
                                {case value="4"}
                                <input type="radio" name="floor" value="1">1~6&nbsp;
                                <input type="radio" name="floor" value="2">6~12&nbsp;
                                <input type="radio" name="floor" value="3">12~18&nbsp;
                                <input type="radio" name="floor" value="4" checked>18~24&nbsp;
                                <input type="radio" name="floor" value="5">24以上
                                {/case}
                                {case value="5"}
                                <input type="radio" name="floor" value="1">1~6&nbsp;
                                <input type="radio" name="floor" value="2">6~12&nbsp;
                                <input type="radio" name="floor" value="3">12~18&nbsp;
                                <input type="radio" name="floor" value="4">18~24&nbsp;
                                <input type="radio" name="floor" value="5" checked>24以上
                                {/case}
                                {/switch}
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房间描述 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" id="user-name" value="{$data['remark']}" name="remark">
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">发布人 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" id="user-name" value="{$data['name']}" name="name">
                                <small></small>
                            </div>
                        </div>
                        <div class="am-form-group">
                            <label for="user-name" class="am-u-sm-3 am-form-label">房东手机号码 <span class="tpl-form-line-small-title">Title</span></label>
                            <div class="am-u-sm-9">
                                <input type="text" class="tpl-form-input" id="user-name" value="{$data['tel']}" name="tel">
                                <small></small>
                            </div>
                        </div>
                        <!--<input type="hidden" name="rental" value="2">-->
                        <!--<input type="hidden" name="hot" value="2">-->
                        <!--<input type="hidden" name="review" value="2">-->

                        <div class="am-form-group">
                            <div class="am-u-sm-9 am-u-sm-push-3">
                                <button class="am-btn am-btn-primary tpl-btn-bg-color-success ">提交</button>
                            </div>
                        </div>
                    </form>

                </div>
            </div>
        </div>


    </div>

</div>
{/block}